1. Field of the Invention
The present disclosure relates to memory management. More specifically, the present disclosure relates to a method and system for maintaining a timestamp-indexed record of memory access operations for a memory pool.
2. Related Art
Computer memory is often managed by allocating multiple memory pools that satisfy different classes of memory allocation requests. A memory pool can be a portion or range of memory (e.g., blocks), and the size of each of the memory pools is typically controlled by and managed through use of separate memory parameters. Some memory management systems may specify static default values for the sizes of each memory pool based on certain heuristics. Other memory management systems require a system administrator to indicate an explicit size for the memory pools.
In practice, the system administrator may manually optimize the size for these memory pools, which can involve an iterative process of trial and error. Unfortunately, the optimal allocation of memory among the memory pools can change over time, as it depends on the type of workload that is occurring on a given application that is using the memory. For example, a database server may employ several memory pools, such as a first pool used for performing backup jobs, and a second pool used for on-line transaction processing (OLTP) activities. If a system is configured to optimize the first pool to accommodate a nightly recovery management backup job, then most of this memory can remain unused for the majority of the day. On the other hand, if the first pool is too small because the system is configured to optimize the second pool, then it is likely that the memory backup jobs may not be performed or completed.
The system administrator may also configure memory allocation parameters for one or more applications, and the memory management system may optimize the size of the memory pools based on these allocation parameters. However, administrators typically may not revisit these allocation parameters, which can cause some pools to become underutilized. This can cause an application to fail when it cannot allocate sufficient memory to memory pools, and can cause performance problems when the system needs to excessively reload data from disk. Thus, some administrators purposely oversize some memory pools to handle the worst-case scenarios to avoid system errors, and to avoid the need to reallocate a memory pool. Unfortunately, oversizing some memory pools to avoid system errors can lead to a significant performance loss for other memory pools.